home *** CD-ROM | disk | FTP | other *** search
/ SGI Hot Mix 17 / Hot Mix 17.iso / HM17_SGI / research / resource / fonts / ps / README.TXT < prev    next >
Encoding:
Text File  |  1997-07-08  |  3.6 KB  |  95 lines

  1. ------------------------------------------------------------
  2. README file: <RSI_Directory>
  3.             <IDL_Directory>    
  4.           resource
  5.             fonts
  6.               ps
  7. IDL Version 5.0
  8. ------------------------------------------------------------
  9.  
  10. This subdirectory contains files with support the IDL PostScript
  11. graphics driver:
  12.  
  13.     ehandler.ps - PostScript Downloaded Error Break-page handler from
  14.     Adobe Systems Incorporated. Normally, any errors in a PostScript
  15.     file cause the printer to silently kill the job. Sending this
  16.     file to your PostScript printer causes it to print any subsequent
  17.     errors it encounters on a sheet of paper and eject it. The effect
  18.     of this file lasts until the printer is reset.
  19.  
  20.     Clearly, a workstation with a PostScript previewer is a
  21.     better way to debug PostScript, but if you only have a printer,
  22.     this is the way to go.
  23.  
  24.     prolog.ps - The PostScript prolog file. This file contains
  25.     standard PostScript definitions used by all IDL generated
  26.     PostScript files. IDL includes a copy of this file at the top
  27.     of every generated output file.
  28.  
  29.     Adobe Font Metric (.afm) files - These files supply font
  30.     metric information which is used by IDL to properly position
  31.     text output.
  32.  
  33.  
  34.     font.map - A text file which maps PostScript font names to the
  35.     name of their corresponding afm file. This approach avoids
  36.     file name length problems that occur on some operating systems.
  37.  
  38.  
  39. ----------------------------------------
  40. To add an Adobe font metric file to IDL:
  41. ----------------------------------------
  42.  
  43.     1) IDL doesn't use standard Adobe AFM files directly. Rather, it uses
  44.        the output of a user library procedure named PSAFM. PSAFM
  45.        takes a standard AFM file as input and creates as output
  46.        an AFM file more to IDLs liking. Use PSAFM to convert
  47.        the Adobe AFM file and place the result in this directory.
  48.        Choose a name of 8 or fewer characters with a ".afm"
  49.        extension. Make sure this name doesn't already appear in
  50.        font.map. Usually the name of the original AFM file is fine:
  51.  
  52.     Example:
  53.  
  54.         IDL> PSAFM, '/home/user/newafm.afm', $
  55.          '/usr/local/rsi/idl/resource/fonts/ps/newafm.afm'
  56.  
  57.     2) Use a standard text editor to add an entry in font.map for the new
  58.        AFM file. The field labeled "ISO encoding?" should be answered by
  59.        looking in your new AFM file for the string "ISOLatin1Encoding.
  60.        If this is found, enter a "1", otherwise enter a "0".
  61.  
  62. --------
  63. Example:
  64. --------
  65.     My development system (Solaris 2.5) comes with a PostScript previewer
  66. named pageview(1) that can be used to examine PostScript output from programs
  67. like IDL. The AFM files for the fonts it understands can be found in
  68. /usr/openwin/lib/X11/fonts/F3/afm. This example will show how to produce
  69. IDL PostScript output that uses the GillSans-BoldItalic font, and then
  70. display the results using pageview. As shipped by RSI, GillSans-BoldItalic
  71. is not one of the fonts that IDL understands by default:
  72.  
  73.     1) Run IDL and use PSAFM to generate the IDL afm file. On most
  74.        systems, you will need root access to create the file in the
  75.        IDL distribution tree:
  76.  
  77.     IDL>PSAFM,'/usr/openwin/lib/X11/fonts/F3/afm/GillSans-BoldItalic.afm',$
  78.         '/usr/local/rsi/idl/resource/fonts/ps/GlS-BoI.afm'
  79.  
  80.     2) Edit the IDL font.map file in the resource/fonts/ps subdirectory of
  81.        the IDL distribution and add the following line at the end:
  82.  
  83.     GillSans-BoldItalic    GlS-BoI    1
  84.  
  85.     3) Run IDL and create a plot:
  86.  
  87.     IDL> set_plot,'ps'
  88.     IDL> device,user_font='GillSans-BoldItalic'
  89.     IDL> plot,[0,1],title='Nonsense Plot',xtit='X',ytitle='Y', FONT=0
  90.     IDL> exit
  91.  
  92.     4) View the results:
  93.  
  94.     % pageview idl.ps
  95.